]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
recorder: Port to new gstreamer vp8enc api
authorAdel Gadllah <adel.gadllah@gmail.com>
Mon, 17 Sep 2012 16:55:02 +0000 (18:55 +0200)
committerAdel Gadllah <adel.gadllah@gmail.com>
Mon, 17 Sep 2012 17:49:04 +0000 (19:49 +0200)
The speed and quality properties have been removed in favor of properties
closer to the upstream library.

Removing the properies from the pipeline would result into a huge
slowdown so we have to map the old values to the new ones.

According to the source code of the old vp8enc element quality maps to
(int)(63 - quality * 6.2) for min_quantizer and max_quantizer, while
speed maps to cpu-used = speed == 0 ? 0 : (speed - 1).

So set min_quantizer and min_quantizer to 13, and cpu-used to 5 based on
the above formulas.

https://bugzilla.gnome.org/show_bug.cgi?id=684206

data/org.gnome.shell.gschema.xml.in.in
src/shell-recorder.c

index d9a1ae858c9bd46cc71ce3456ee1f9a9946adf9e..18eac2c4d0cf32be73e49aab05ada20efe197471 100644 (file)
@@ -132,7 +132,7 @@ value here is from the GsmPresenceStatus enumeration.</_summary>
         take care of its own output - this might be used to send the output
         to an icecast server via shout2send or similar. When unset or set
         to an empty value, the default pipeline will be used. This is currently
-        'vp8enc quality=8 speed=6 threads=%T ! queue ! webmmux'
+        'vp8enc min_quantizer=13 max_quantizer=13 cpu-used=5 deadline=1000000 threads=%T ! queue ! webmmux'
         and records to WEBM using the VP8 codec. %T is used as a placeholder
         for a guess at the optimal thread count on the system.
       </_description>
index 2c82fdab313a76c7a35fc03261eafd38b5dda6ea..9dd74828219661908f43c63cb71adc7e61fcb437 100644 (file)
@@ -143,7 +143,7 @@ G_DEFINE_TYPE(ShellRecorder, shell_recorder, G_TYPE_OBJECT);
  * (Theora does have some support for frames at non-uniform times, but
  * things seem to break down if there are large gaps.)
  */
-#define DEFAULT_PIPELINE "vp8enc quality=8 speed=6 threads=%T ! queue ! webmmux"
+#define DEFAULT_PIPELINE "vp8enc min_quantizer=13 max_quantizer=13 cpu-used=5 deadline=1000000 threads=%T ! queue ! webmmux"
 
 /* If we can find the amount of memory on the machine, we use half
  * of that for memory_target, otherwise, we use this value, in kB.
@@ -1598,7 +1598,7 @@ shell_recorder_set_filename (ShellRecorder *recorder,
  * might be used to send the output to an icecast server
  * via shout2send or similar.
  *
- * The default value is 'vp8enc quality=8 speed=6 threads=%T ! queue ! webmmux'
+ * The default value is 'vp8enc min_quantizer=13 max_quantizer=13 cpu-used=5 deadline=1000000 threads=%T ! queue ! webmmux'
  */
 void
 shell_recorder_set_pipeline (ShellRecorder *recorder,